package com.lesson10.composite;

/**
 * @author 朝花不迟暮
 * @version 1.0
 * @date 2020/8/31 16:36
 */
public abstract class OragizationComposite
{
    private String name;
    private String desc;

    public OragizationComposite(String name, String desc)
    {
        this.name = name;
        this.desc = desc;
    }

    protected void add(OragizationComposite o){
        throw new UnsupportedOperationException();
    }

    protected void remove(OragizationComposite o){
        throw new UnsupportedOperationException();
    }

    public String getName()
    {
        return name;
    }

    public void setName(String name)
    {
        this.name = name;
    }

    public String getDesc()
    {
        return desc;
    }

    public void setDesc(String desc)
    {
        this.desc = desc;
    }

    protected abstract void print();
}
